package org.devops


//实现build方法。
// 构建类型
def Build(buildType,buildshell){
    def buildTools=["mvn":"mvn","ant":"ant","gradle":"gradle","npm":"npm"] //定义构建工具类型列表

    println("当前选择的构建类型为 ${buildType}")
    buildHome=tool buildTools[buildType]

    sh "${buildHome}/bin/${buildType} ${buildshell}"
}